Skip to content

Update azure-healthinsights-radiologyinsights SDK from local TypeSpec #41951

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

scbedd
Copy link
Member

@scbedd scbedd commented Jul 9, 2025

Debugging a possible issue with APIView. Does this properly generate a new APIView entry?

- Updated SDK using local TypeSpec spec from C:\Users\caperal\repos\azure-rest-api-specs\specification\ai\HealthInsights\HealthInsights.RadiologyInsights
- Added new custom inference functionality with begin_custom_inference method
- Fixed import-error pylint warnings for collections.abc.MutableMapping imports
- Fixed no-value-for-parameter pylint warning in model_base.py
- Updated client operations mixin class names to follow new naming convention
- Fixed setup.py package folder path resolution
- All static validation (Pylint, MyPy, Pyright, Sphinx) now passes successfully

touch a different file harmlessly
@Copilot Copilot AI review requested due to automatic review settings July 9, 2025 01:05
@scbedd scbedd self-assigned this Jul 9, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the azure-healthinsights-radiologyinsights SDK generated from a local TypeSpec, introducing a new custom inference operation and adjusting package structure and APIView mappings.

  • Refactor setup.py to derive the package folder path from PACKAGE_NAMESPACE.
  • Add build_radiology_insights_custom_inference_request and corresponding custom inference methods to both sync and async operation mixins.
  • Rename the operations mixin to a private _RadiologyInsightsClientOperationsMixin, update client classes to subclass it, and add new APIView entries for begin_custom_inference.

Reviewed Changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated no comments.

Show a summary per file
File Description
sdk/healthinsights/azure-healthinsights-radiologyinsights/setup.py Use PACKAGE_NAMESPACE to build package_folder_path.
sdk/healthinsights/.../aio/_operations/_operations.py Add custom inference request builder, methods, and rename mixin.
sdk/healthinsights/.../aio/_operations/init.py Remove public export of the old mixin.
sdk/healthinsights/.../aio/_client.py Update client to subclass the private mixin.
sdk/healthinsights/.../_utils/model_base.py Disable pylint error for super().__new__.
sdk/healthinsights/.../_operations/_operations.py Add sync custom inference builder, methods, and rename mixin.
sdk/healthinsights/.../_operations/init.py Remove public export of the old mixin.
sdk/healthinsights/.../_client.py Update client to subclass the private mixin.
sdk/healthinsights/azure-healthinsights-radiologyinsights/apiview-properties.json Add APIView entries for begin_custom_inference.
Comments suppressed due to low confidence (3)

sdk/healthinsights/azure-healthinsights-radiologyinsights/azure/healthinsights/radiologyinsights/aio/_client.py:20

  • [nitpick] Renaming the operations mixin to a private class (_RadiologyInsightsClientOperationsMixin) and using it in a public client can confuse consumers. Consider keeping a public mixin name or documenting the change to avoid breaking downstream code.
from ._operations._operations import _RadiologyInsightsClientOperationsMixin

sdk/healthinsights/azure-healthinsights-radiologyinsights/azure/healthinsights/radiologyinsights/aio/_operations/_operations.py:297

  • New custom inference logic has been introduced but there are no corresponding tests. Please add unit or integration tests for _custom_inference_initial and begin_custom_inference to ensure proper coverage.
    async def _custom_inference_initial(

sdk/healthinsights/azure-healthinsights-radiologyinsights/azure/healthinsights/radiologyinsights/aio/_operations/_operations.py:353

  • The exceptions StreamConsumedError and StreamClosedError are caught but not imported, which will cause a NameError. Please import them from the appropriate module, for example from azure.core.exceptions import StreamConsumedError, StreamClosedError.
            except (StreamConsumedError, StreamClosedError):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants